package model;

import lombok.Data;

import java.util.Date;
@Data
/*7 加上这个Data 会自动生成get set */
public class Student {
    private long id;
    private String name;
    private String  sno;
    private Integer age;
    private Byte gender;
    private Date enrollDate;//命名要变成java的命名规则
    private long classId;

    //5 关联的班级对象
    private Classes classes;

    //自动生成get set 方法

   /*7 public long getId() {
        return id;
    }

    public String getName() {
        return name;
    }

    public String getSno() {
        return sno;
    }

    public Integer getAge() {
        return age;
    }

    public Byte getGender() {
        return gender;
    }

    public Date getEnrollDate() {
        return enrollDate;
    }

    public long getClassId() {
        return classId;
    }

    public void setId(long id) {
        this.id = id;
    }

    public void setName(String name) {
        this.name = name;
    }

    public void setSno(String sno) {
        this.sno = sno;
    }

    public void setAge(Integer age) {
        this.age = age;
    }

    public void setGender(Byte gender) {
        this.gender = gender;
    }

    public void setEnrollDate(Date enrollDate) {
        this.enrollDate = enrollDate;
    }

    public void setClassId(long classId) {
        this.classId = classId;
    }

    public Classes getClasses() {
        return classes;
    }

    public void setClasses(Classes classes) {
        this.classes = classes;
    }*/
}
/*接下来再创建一个dao包，对数据库的访问做一些操作*/